# Contributor: Steeve Chailloux <steeve.chailloux@orus.io>
# Maintainer: Steeve Chailloux <steeve.chailloux@orus.io>
pkgname=s3fs-fuse
pkgver=1.91
pkgrel=0
pkgdesc="FUSE-based file system backed by Amazon S3"
options="!check" # Fails to connect to localhost
url="https://github.com/s3fs-fuse/s3fs-fuse"
arch="all"
license="GPL-2.0-only"
makedepends="automake autoconf libxml2-dev fuse-dev curl-dev git bash"
checkdepends="coreutils sed"
subpackages="$pkgname-doc"
source="$pkgname-$pkgver.tar.gz::https://github.com/s3fs-fuse/s3fs-fuse/archive/v$pkgver.tar.gz"

prepare() {
	default_prepare
	./autogen.sh
}

build() {
	./configure \
		--build=$CBUILD \
		--host=$CHOST \
		--prefix=/usr \
		--sysconfdir=/etc \
		--mandir=/usr/share/man \
		--localstatedir=/var
	make
}

check() {
	make check
}

package() {
	make DESTDIR="$pkgdir" install
}

sha512sums="
5b57af18395f34885b4b8a98e93b0e3f9043c9af78e415a0a6c15489611d7e21ae619e69655737de369edee15762d8726b82bc2651b5b7f5c20e26fe866a96bc  s3fs-fuse-1.91.tar.gz
"
